<template>
  <div v-if="errorState!==0">
    <frontend-error-page-std></frontend-error-page-std>
  </div>
  <router-view v-else />
  <njt-message-box></njt-message-box>
  <error-list-display></error-list-display>
</template>


<script setup lang="ts">
// 获取package.json的任务只能放在项目中，不能放在lib中
import {NjtPackInfoDef, PackageInfoDef} from '@njt/foundation/defs/comm'
import packageJson from 'app/package.json'
import {prepareNotify} from '@njt/foundation/helper/ui'
const njtPackInfo: NjtPackInfoDef = packageJson.njtconfig
const packageInfo: PackageInfoDef = {
  njtconfig: njtPackInfo,
  productName: packageJson.productName,
  version: packageJson.version,
  copyrightYear: new Date().getFullYear().toString()
}
$f.packageInfo = packageInfo
// 特殊处理: 由于useQuasar必须要在setup()中调用才有效，对notify的初始化需要放在这里
prepareNotify()
const errorState = $f.errorState

</script>

